-
Notifications
You must be signed in to change notification settings - Fork 629
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: print warning on use of deprecated API #4200
Conversation
warnDeprecatedApi()
I think this tool is good enough for first pass. |
deno.json
Outdated
@@ -12,7 +12,7 @@ | |||
"automation/": "https://raw.githubusercontent.com/denoland/automation/0.10.0/" | |||
}, | |||
"tasks": { | |||
"test": "deno test --doc --unstable --allow-all --parallel --coverage --trace-ops", | |||
"test": "NO_DEPRECATION_WARNINGS=1 deno test --doc --unstable --allow-all --parallel --coverage --trace-ops", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is needed for cases where we must still continue to test deprecated APIs.
internal/mod.ts
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does having an internal
folder interfere with workspaces functionality, @lucacasonato?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, this interferes with workspaces.
How can we make internal tools and workspaces work? What are some options? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
This function prints a friendly warning if the given deprecated API is being used. This implementation is based on denoland/deno#21939, but with a few differences that make more sense for the Standard Library.